home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgramD2.iso / Visual Database / Visual Foxpro 6.0 (Ent. Edition) / Vf6ent Extractor.EXE / TOOLS / XSOURCE / XSOURCE.ZIP / vfpsource / wizards / Wzfoxdoc / keywrd.prg < prev    next >
Encoding:
Text File  |  1998-05-01  |  2.6 KB  |  105 lines

  1. * THIS FILE SHOULD NOT BE LOCALIZED!!!
  2.  
  3. *- author: calvinh
  4. *- This program creates the keyword table for foxdoc
  5. *- it requires fdindent.dbf
  6. *- 
  7. *-   I Indent
  8. *-   U Undent
  9. *-   R Reset indentation to 0 (or 1 if InDefineClass)
  10. *-   F Proc or function
  11. *-   D While or Case: DO clause
  12. *-   O Object (Spinner,CommandButton)
  13. *-   P Property (Scalemode,DecimalPoints)
  14. *-   M Method (Init,KeyPress)
  15. *-   C Clause  Used only as a Clause: can't start a statement
  16. *-
  17. set dele on
  18. set exac off
  19. close data
  20. create curs tokenp (token c(100),code c(5))
  21. appe from \fox30\source\property.src sdf
  22. repl all token with strtran(token,chr(9),"")
  23. dele all for !(token="PROPERTY" or token="CLASSLIST")
  24. repl all code with 'O' for token="CLASSLIST"
  25. repl all code with 'P' for token="PROPERTY"
  26. repl all code with 'M' for "TYPEEVENT"$token OR "TYPEMETHOD"$token
  27. repl all token with subs(token,at('"',token)+1)
  28. repl all token with left(token,at('"',token)-1) FOR at('"',token)>0
  29. repl all token with left(token,at('(',token)-1) FOR at('(',token)>0
  30. dele all for token=' '
  31. dele all for ' '$alltrim(token)
  32. copy to keyp
  33.  
  34. create curs tokenk (token c(100),code c(5))
  35. appe from \fox30\source\nonloc.src sdf
  36. *Delete the color schemes
  37. dele all while token#"#HEADER KEYWORD.H"
  38.  
  39. dele all for occurs('"',token)#2
  40. repl all token with strtran(token,chr(9),"")
  41. repl all code with 'C' for token="OVK"    && clause
  42. dele all for token# 'OV'
  43. repl all token with subs(token,at('"',token)+1)
  44. repl all token with left(token,at('"',token)-1) FOR at('"',token)>0
  45. dele all for token=' '
  46. dele all for val(token)>0
  47. dele all for token='\'
  48. dele all for token="'"
  49. repl all token with left(token,at('(',token)-1) FOR at('(',token)>0
  50. dele all for ' '$alltrim(token)
  51. DELE ALL FOR UPPER(token)="PARAMETERLIST"
  52. copy to keyk for !EMPTY(token)
  53. sele 0
  54. use fdkeywrd
  55. sele 0
  56. create table keywrd1 (token c(22),code c(5))
  57. appe from keyp
  58. appe from keyk
  59. inde on upper(token) tag token uniq
  60. copy to keywrd
  61. use keywrd
  62. erase keywrd1.dbf
  63. inde on upper(token) tag token
  64.  
  65. if file ("fdindent.dbf")
  66.  
  67.     wait window nowait "now updating indent codes"
  68.     sele 0
  69.     use fdindent
  70.     scan
  71.         select keywrd
  72.         seek upper(fdindent.token)
  73.         if found()
  74.             repl code with fdindent.code
  75.         else
  76.             insert into keywrd (token,code) values ;
  77.                 (fdindent.token,fdindent.code)
  78.         endif
  79.     endscan
  80.     SELECT fdkeywrd
  81.     zap
  82.     appe from keywrd
  83.     set orde to 1
  84. endif
  85.  
  86. brow last nowait
  87. wait clear
  88.  
  89. retu
  90.  
  91.  
  92.  
  93. sele upper(token) from fdkeywrd where Upper(token) not in;
  94.     (select upper(token) from keywrd)
  95.  
  96.  
  97. *American,this,thisform,thisformset
  98.  
  99. In nonloc, sysmenu(s),disable(d)
  100.  
  101.  
  102. strings.src
  103. STRINGS STROVL_MISC, BYITEM
  104.  
  105.